import time
class xiansou(object):
    def __init__(self,driver):
        self.driver=driver


    # def mc(self,aa):
    #     aa = "名称" + time.strftime('%Y%m%d%H%M%S', time.localtime(time.time()))
    #     self.aa = aa
    #     return aa


    def xiansuo(self):
        self.driver.find_element_by_xpath("//span[text()='新建线索']").click()
        time.sleep(2)
        aa = "名称" + time.strftime('%Y%m%d%H%M%S', time.localtime(time.time()))
        self.driver.find_element_by_xpath('//div/form/div[1]/div/div/input').send_keys(aa)
        time.sleep(2)
        self.driver.find_element_by_xpath('//form/div[7]/div/div/input').send_keys('江西省')
        time.sleep(2)
        self.driver.find_element_by_xpath('//div/div[3]/button[2]/span').click()
        time.sleep(2)
        return aa


    def bbcxiansuo(self):
        self.driver.find_element_by_xpath("//span[text()='新建线索']").click()
        time.sleep(2)
        aa = "名称" + time.strftime('%Y%m%d%H%M%S', time.localtime(time.time()))
        self.driver.find_element_by_xpath('//div/form/div[1]/div/div/input').send_keys(aa)
        time.sleep(2)
        self.driver.find_element_by_xpath('//form/div[7]/div/div/input').send_keys('江西省')
        time.sleep(2)
        return aa

